import React from "react";
class List extends React.Component {
    state = {
        arr: ["赵云", "吕布", "阿轲", "甄姬", "虞姬", "项羽"]
    }
    render() {
        let lis=this.state.arr.map((item,index)=><li key={index}><h1>{item}</h1></li>)
        return (
            <fieldset>
                <legend>列表</legend>
                <ul>
                    <li>{lis}</li>
                </ul>
            </fieldset>
        )
    }
}
export default List
